﻿using System;
using System.Collections.Generic;
using EnetaMvc.ApplicationServices.Dto;
using EnetaMvc.Infrastructure;

namespace EnetaMvc.ApplicationServices
{
    public interface IForumService
    {
        IList<ForumCategoryDto> ListForumCategories();
        ForumCategoryDto GetForumCategoryById(long id);
        ForumDto GetForumById(long id);
        ForumDto GetForumByPostId(long id);
        PagedResult<ForumPostDto> ListPostsForForum(long id, int page, int pageSize);
        IList<ForumPostDto> GetForumThread(long postId);
        ForumPostDto GetPostById(long id);
        void AddReplyToPost(long postId, string author, string reply);
        void AddTopicToForum(long forumId, string author, string title, string body);
        void IncreaseTopicViewCount(long topicId);
        IList<ForumPostDto> ListLastTopicsForRss();
        IList<ForumPostDto> ListLastRepliesForRss();
        IList<ForumPostDto> ListLastTopicsForCategoryRss(long categoryId);
        IList<Tuple<ForumDto, IList<ForumPostDto>>> ListLastTopicsOverForums();
        void SaveCategory(ForumCategoryDto categoryDto);
        void DeleteCategory(long id);
        void SaveForum(ForumDto forumDto);
        void DeleteForum(long id);
        void DeletePost(long id);
    }
}
